package com.ylbh.modules.sign.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ylbh.common.pojo.sign.dto.SignTurntableDTO;
import com.ylbh.common.pojo.sign.vo.ShoppingSigninPrizeVO;
import com.ylbh.common.pojo.sign.vo.ShoppingSigninTurntableInfoVO;
import com.ylbh.modules.sign.entity.ShoppingSigninPrize;
import com.ylbh.modules.sign.entity.ShoppingSigninTurntableInfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 转盘信息列表
 * @author wjc
 * @date 2019-011-06 14:22:40
 */
@Mapper
@Repository
public interface ShoppingSignTurntableMapper {

    /**
     * 帮助回复问题配置列表
     * @param signTurntableDTO
     * @return
     */
    List<ShoppingSigninTurntableInfoVO> selectSignTurntableList(SignTurntableDTO signTurntableDTO, Page page);

    /**
     * 转盘信息子列表
     * @param
     * @return
     */
    List<ShoppingSigninPrizeVO> selectSubSignPrizeListById(@Param(value = "id") Integer id);
    /**
     * 添加活动模板
     * @param info
     * @return
     */
    void insertShoppingSigninTurntableInfo(ShoppingSigninTurntableInfo info);
    /**
     * 删除模板信息
     * @param ids
     * @return
     */
    void deleteTurntableByIds(@Param(value="ids") List<Integer> ids);

    /**
     * 获取模信息ById
     * @param id
     * @return
     */
    ShoppingSigninTurntableInfo selectTurntableById(@Param(value="id") Integer id);
    /**
     * 根据ID修改模板信息
     * @param info
     * @return
     */
    void updateShoppingSigninTurntableInfo(ShoppingSigninTurntableInfo info);

    /**
     * 修改模板状态
     * @param signTurntableDTO
     * @return
     */
    void updataTurnTableEnableStateById(SignTurntableDTO signTurntableDTO);
    /**
     * 查询表开启状态总数
     * @return
     */
    int selectCountEnable();
}
